package com.itshen.mapper;

import com.itshen.common.CommonMapper;
import com.itshen.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * @author stephen
 * @date 2018-07-08 20:44
 */
@Mapper
public interface UserMapper extends CommonMapper<User> {

    @Select("SELECT * FROM user WHERE username = #{username}")
    User findByUsername(@Param("username") String username);

    @Select("SELECT * FROM user WHERE id = #{Id} ")
    User findUserById(@Param("Id") String Id);
}
